<%@ page language="java" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
	<head>
		
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
		<meta name="viewport"	content="width=device-width,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no" />
		
		<link rel="stylesheet" type="text/css" href="${pageContext.request.contextPath}/css/bootstrap.min.css">
		<link rel="stylesheet" href="${pageContext.request.contextPath}/bettery/css/itao.css">
		<script type="text/javascript" src="${pageContext.request.contextPath}/dewei/js/jquery.js"></script>
		<script type="text/javascript" src="${pageContext.request.contextPath}/bettery/js/jquery.validate.min.js"></script>
		<script type="text/javascript" src="${pageContext.request.contextPath}/bettery/js/bettery_common.js"></script>
		<script type="text/javascript">
		$(function(){
			getaddressByLatLngGaode();
			jQuery.validator.addMethod("mobilePhone", function(value, element) {var length = value.length;var tel = /^((1[3|4|5|8]{1}[0-9]{1})+\d{8})$/;return this.optional(element) || (length == 11 && tel.test(value));}, "格式错误 ");
			validator = $("#searchForm").validate({
			rules : {
				"model.kehuName" : {
					required : true
				},
				"model.lxTel" : {
					required : true,
					mobilePhone:true
				},
				"model.address":{
				    required : true	
				}
			},
			messages : {
				"model.kehuName" : {
					required : "必选"
				},
				"model.lxTel" : {
					required : "必选",
					mobilePhone:"格式错误"
				},
				"model.address":{
				    required : "必选"
				}
			},
			errorPlacement : function(error, element) {
				element.removeClass("error");
		    }
		});
			});
		</script>
		<style type="text/css">
			.slide .inner-scroll{
				left: 0px;top: 0px;height: 100%;overflow-y:auto;
			}
			.bx-wrapper div.footer_bar{
				position: absolute;bottom: 0px;
			}
			
		   
		</style>
	</head>
	<body onload="hideLoading()">
	 <form id='searchForm' action="toConfirm.do"  method="post">
			<input type="hidden" value="${model.lat}" name='model.lat' id="hiddenLat"/>
			<input type="hidden" value="${model.lng}" name='model.lng' id="hiddenLng"/>
			<input type="hidden" value="${model.blat}" name='model.blat' id="hiddenbLat"/>
			<input type="hidden" value="${model.blng}" name='model.blng' id="hiddenbLng"/>
			<input type="hidden" value="${model.chexingId}" name="model.chexingId" id="chexingId"/>
			<input type="hidden" value="${model.chexingName}" name="model.chexingName" id="hiddenChexingName"/>
			<!-- 下订单人所在的省市县 -->
		    <input type="hidden" value="${model.province}" name='model.province' class="hiddenProvince" id="hiddenProvince"/>
		    <input type="hidden" value="${model.city}" name='model.city' class="hiddenCity" id="hiddenCity"/>
		    <input type="hidden" value="${model.town}" name='model.town' class="hiddenTown" id="hiddenTown"/>
		    <!-- 电池 -->
			<input type="hidden" value="${model.dianchiId}" name="model.dianchiId" id="dianchiId"/>
			<input type="hidden" value="${model.price}" name='model.price' id="ourPrice"/>
			<input type="hidden" value="${model.pinPai}" name='model.pinPai' id="pinPai"/>
			<input type="hidden" value="${model.xingHao}" name='model.xingHao' id="xingHao"/>
			<input type="hidden" value="${model.imageUrl}" name='model.imageUrl' id="imageUrl"/>
			<input type="hidden" value="${model.zhongliang}" name='model.zhongliang' id="bettery_zhongliang"/>
			<input type="hidden" value="${model.licheng}" name='model.licheng' id="bettery_licheng"/>
		    <input type="hidden" value="${model.detailInfo}" name='model.detailInfo' id="bettery_detailInfo"/>
		    <input type="hidden" value="${model.marketPrice}" name='model.marketPrice' id="bettery_marketPrice"/>
			<!-- 1:门店，2：上门 -->
			<input type="hidden" name='model.changeType' value="附近无网点" id="hiddenChangeType"/>
			
			<!-- 门店地址 -->
			<input type="hidden" value="${model.mendianAddr}" name='model.mendianAddr' id="hiddenmendianAddr"/>
			<input type="hidden" value="${model.mendianId}" name='model.mendianId' id="hiddenMendianId"/>
			<!-- 门店联系电话 -->
			<input type="hidden" value="${model.menDianTel}" name='model.menDianTel' id="hiddenMenDianTel"/>
			<input type="hidden" value="${model.mendianLxr}" name='model.mendianLxr' id="hiddenMendianLxr"/>
			<input type="hidden" value="${model.mendianName}" name='model.mendianName' id="hiddenMendianName"/>

		 <input type="hidden" id="tsss">
		<div class="search_bar" style="" align="center">
		<span class='new-btn left'>
		<a    onclick="back();">返回</a>
		</span>
		<span class="new-btn  right"><a onclick="javascript:submitdingdan();">确定</a>
		</span>
		</div>
		<div class='tips'>附近没有门店，您可以联系客服</div>
		<div   class="col-lg-12 m-t">
			<div class='panel'>
			<div class='panel-body'>
			    <div class='form-group'>
					<label class='form-caption'><font color="red">*</font>姓名</label><label class="error" for="lianxiName"></label>
					<input type="text" id="lianxiName"  name="model.kehuName" value="${model.kehuName}" maxlength="30" class="form-control" placeholder="姓名"> 
				</div>
				<div class='form-group'>
					<label class='form-caption'><font color="red">*</font>手机号</label><label class="error" for="lianxiKefuTel"></label>
					<input type="text" id="lianxiKefuTel" name="model.lxTel" value="${model.lxTel}" maxlength="11" class="form-control" placeholder="手机号"> 
				</div>
				<div class='form-group'>
		            <label class='form-caption'><font color="red">*</font>预约上门地址</label><label class="error" for="lianxiAddr"></label>
					<div class="input-group">
					  <input type="text" id="lianxiAddr" name="model.address" value="${model.address}" maxlength="100" class="form-control address"  placeholder="地址" >
					  <span class="input-group-addon" onclick="autoAddr();"><img src='../dewei/img/loc.png' width='18px'> </span>
					</div>
	            </div>
			</div>
			</div>
		</div>
		 
		</form>
	</body>
</html>